﻿using ApplicationBase.Core.Context;
using ApplicationBase.Core.Helpers;
using ApplicationBase.Core.Utils;
using Microsoft.Extensions.DependencyInjection;

namespace Infrastructure.Test
{
    public class Startup
    {
        public void ConfigureServices(IServiceCollection services)
        {
            services.AddSingleton<IFileHelper, DefaultFileHelper>();
            services.AddSingleton<IClock, UTCClock>();
            services.AddSingleton<IServiceContext, ServiceContext>();

            //Test start
            services.Configure<TestOption>(option =>
            {
                option.Option1 = "I'm OP1";
                option.Option2 = "I'm OP2";
            });
            services.AddSingleton<UseOption>();
            //Test end
        }
    }
}
